﻿using System.Collections.ObjectModel;

namespace NxChatQQ.Models
{
    public class TreeFriendModel
    {
        public string Name { get; set; }

        public int Online { get; set; }
        public int Count
        {
            get
            {
                if (Items != null)
                {
                    return Items.Count;
                }
                return 0;
            }
        }

        public bool IsTitle { get { return Friend == null; } }

        public bool IsExpanded { get; set; }

        public Friend Friend { get; set; }

        public ObservableCollection<TreeFriendModel> Items { get; set; }
    }
}
